home *** CD-ROM | disk | FTP | other *** search
/ Mac Magazin/MacEasy 32 / Mac Magazin and MacEasy Magazine CD - Issue 32.iso / Multimedia / MIDI / JUNO Librarian 1.1.7 / Sample Scripts / 20 Change DCO PWM ON⁄OFF < prev    next >
Text File  |  1994-01-28  |  388b  |  17 lines

  1. tell application "JUNO Librarian"
  2.     activate -- if needed
  3.     set x to Parameter 16 of Window "Sample"
  4.     set y to (round (x ÷ 8) rounding down)
  5.     set y to y * 8
  6.     set z to x - y -- DCO range
  7.     set y to (round (y ÷ 16) rounding down)
  8.     set y to y * 16
  9.     set x to y + z
  10.     
  11.     -- select 1 of 2
  12.     set x to x + 0 -- PWM OFF
  13.     --    set x to x + 8 -- PWM ON
  14.     
  15.     copy x to Parameter 16 of Window "Sample"
  16. end tell
  17.